package Swing;
import javax.swing.*;
public class checkboxExam {
	static final int WIDTH=300;
	static final int HEIGHT=200;
	public static void main(String[] args) {
		JFrame jf = new JFrame("checkbox example");
		jf.setSize(WIDTH,HEIGHT);
		jf.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);
		jf.setVisible(true);
		JPanel contentPane = new JPanel();
		jf.setContentPane(contentPane);
		
		JCheckBox jc1 = new JCheckBox("Badminton");
		JCheckBox jc2 = new JCheckBox("Football");
		JCheckBox jc3 = new JCheckBox("Computer");
		JCheckBox jc4 = new JCheckBox("Mathematics");
		JCheckBox jc5 = new JCheckBox("Film");
		JCheckBox jc6 = new JCheckBox("Video");
		contentPane.add(jc1);
		contentPane.add(jc2);
		contentPane.add(jc3);
		contentPane.add(jc4);
		contentPane.add(jc5);
		contentPane.add(jc6);
	}
}